﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Sinacor.Infra.Core.Licensing.Data
{
    public static class TypeExtensionMethods
    {
        public static bool IsNullable(this System.Type type)
        {
            if (type == null)
                throw new ArgumentException("The parameter canot be null", "type");

            return (type.IsGenericType && (type.GetGenericTypeDefinition() == typeof(System.Nullable<>)));
        }
    }
}
